package com.gateio.flutter.lib_core

import android.util.Log


/**
 * Author: Shper
 * Created: 2023/9/5
 */
object GTFlutterMessageChannelImpl : GTMessageChannelHostApi {

    override fun handleMessage(actionType: String, actionName: String, messageJson: String) {
        Log.d("GTFlutter","handleMessage - actionType: $actionType, actionName:$actionName, messageJson: $messageJson")
        // 校验消息合法性
        if (actionType.isBlank() || actionName.isBlank()) {
            Log.e("GTFlutter", "The actionType or actionName is empty!")
            return
        }
        GTFlutterMessageCenter._dispatchMassage(actionType, actionName, messageJson);
    }

}